-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Configure Alloy to be use as a self-service tool for logs (source podlogs) #233
Conversation
a78017e
to
5346e2c
Compare
8745ab8
to
7c17e02
Compare
* Refactor PodLogsGetter
A different Alloy config is now generated when observability-bundle is below or above/equal to 1.7.0. |
Co-authored-by: Quentin Bisson <[email protected]>
I don't see anything regarding multi-tenancy. Does it mean all logs are sent to the default orgid? |
Yes I removed the multi-tenancy configuration for now as I could not make it work. Should we add that ? I would need some help on this then. |
Well, I'm not sure multi-tenancy is needed for a first iteration, but I'm quite confident it's needed before our customers would use this feature. |
Maybe they should be sent to the cluster_id tenant for now and we revisit once the multi-tenancy epic is closed. This should be revisited once we start with multi-tenancy for logs right @Rotfuks ? |
Going with this and we can treat the multi-tenancy and tenant override later on then. |
Towards: giantswarm/roadmap#3518
This PR add the capability to dynamically configure log targets using the
giantswarm.io/logging
label. This label can be used on Pods and Namespaces. This label can take 2 distinct valuestrue
orfalse
, when the label is not set its consideredfalse
.Examples
logging=true
logging=false
logging unset
logging=true
logging=false
logging unset
logging=true
: short version forgiantswarm.io/logging=true
labellogging=false
: short version forgiantswarm.io/logging=false
labellogging unset
: short version for nogiantswarm.io/logging
label setThis is achieved by using
PodLogs
to discover targets, which lead to log lines being tailed through Kubernetes API server instead of fetching them from disk, this has some performance impact being describe here giantswarm/roadmap#3518 (comment).clustering
is enabled in order to spread the load across the different Alloy pods/nodes.The new PodLogs resources added do respect the previous default behaviour:
Alloy graph before
Alloy graph after